package com.github.ybq.android.spinkit.dialog;

import android.os.Bundle;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;

import androidx.annotation.NonNull;
import androidx.annotation.Nullable;
import androidx.fragment.app.DialogFragment;

import com.github.ybq.android.spinkit.R;
import com.github.ybq.android.spinkit.SpinKitView;
import com.github.ybq.android.spinkit.SpriteFactory;
import com.github.ybq.android.spinkit.Style;
import com.github.ybq.android.spinkit.sprite.Sprite;

/**
 * @author Administrator
 * @createTime 2019/9/27 17:31
 */
public class MySpinKitDialog extends DialogFragment {
    @Nullable
    @Override
    public View onCreateView(@NonNull LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) {
        View view = inflater.inflate(R.layout.dialog_loading, null);
        SpinKitView spinKitView = (SpinKitView) view.findViewById(R.id.spin_kit);
        Sprite drawabble = SpriteFactory.create(Style.WAVE) ;
        spinKitView.setIndeterminateDrawable(drawabble);
        return view;
    }

    @Override
    public void onStart() {
        super.onStart();

    }
}
